import time
s=open("m1_sorted.txt")
a=[int(x) for x in s]
n=len(a)
t0=time.time()
for j in range(n-1):
    f=0
    for i in range(n-j-1):
        if a[i]>a[i+1]:
            a[i], a[i+1]=a[i+1], a[i]
            f=1
            if f==0:
                break
t2=time.time()
print('m1_sorted',round((t2-t0)*1000), 'milliseconds')
        
